jquery set href of link

64

jquery set href of link -

$('.element').attr('href', newUrl);

how to edit the link in a href with jquery -

$("a").attr("href", "http://www.google.com/")

jquery get link href value -

$("#mylink").attr("href");

Comments

Submit
0 Comments